As a storage device of a computer, an external storage device using a removable storage medium is widely used. For this storage medium, various types are used, including a magnetic disk, optical disk, magneto-optical disk and semiconductor memory. The storage capacity of such an external storage medium has been increasing each year, but it is desired that the price of the drive device for regenerating, recording or erasing information of these external storage medium will further decrease.
Generally speaking, a storage device (drive) is comprised of a drive unit for driving a storage medium, MPU, ROM, RAM and an interface with the host computer (e.g. PC). The removable storage medium is inserted into the drive unit and then can be used.
Conventionally, the control program of the drive is stored statically on ROM and the program stored on ROM is executed by the MPU. And to execute a program on ROM, the data area which the program requires is secured on RAM.
For example, in a disk drive, a READ instruction, which is sent from the host computer, is executed according to the following procedure.
(1) Since the instruction is sent from the host computer, the main program calls up the instruction interpreter program on ROM.
(2) The instruction interpreter program judges that the instruction sent is a READ instruction.
(3) Since the instruction is judged as a READ instruction, the main program calls up the READ program on ROM.
(4) The READ program judges the start sector and the number of sectors to be read from the start sector-on the medium.
(5) The READ program calls up the cache program on ROM and queries whether data on the sectors to be read exists in the cache data.
(6) If applicable data exists, the cache program provides the data to the READ program. If applicable data does not exist, the cache program calls up the medium access program on ROM, reads applicable data on the medium, and provides the read data to the READ program.
(7) The program provides the read data to the host computer via the interface program.
In this way, a conventional drive device stores all the control programs of the drive on ROM in advance, so a ROM which has sufficient capacity to store all the programs is required. To decrease the ROM capacity of the drive device, a control program is stored in an area of the hard disk, in a hard disk drive where a disk is fixed in the device (e.g. Japanese Patent Laid-Open No. 5-12026).
This method, however, allows a fixed disk, fixed in the device (i.e. fixed within a non-removable storage device) to share a part of the control program of the drive device, and a capacity to store control programs is not changed in the entire storage area of the device. For this, it is necessary to store control programs which are not really needed when the user uses the drive device. For example, even when the user desires not to use the cache program, the program must be stored on ROM or the disk.
At the same time, a plurality of program which do not operate simultaneously are stored on ROM, so the capacity of a non-operating program must also be secured in a memory area totaling the ROM and RAM. For example, a disk program for a PC and a disk program for AV (Audio/Visual) have respective control programs, like a cache program, optimized for respective purposes, which operate but never operate simultaneously. Both of these control programs must be stored in the memory area, which makes decreasing cost difficult.
Another problem is that when a minimal control program is mounted, a cache program matching the characteristic of the removable storage medium cannot be used even if the capacity and logical format are different on a removable storage medium, such as an MO. Also adding a program is difficult, and increasing the functions of the drive is difficult as well.
On the other hand, a method for installing a program to be executed by a host, such as a personal computer, using a floppy disk (e.g. Japanese Patent Laid-Open No. 5-120024), or a method of adding a program to a host using a CD-ROM where a program (e.g. read software) and data to be executed by the host, are stored, and performing data processing. These methods, however, are for installing a program to be executed by a host and not for changing the functions of a drive device, so the functions of the drive device cannot be changed by these methods.